home *** CD-ROM | disk | FTP | other *** search
-
-
-
- Sync_Wait C Library Procedures Sync_Wait
-
-
-
- _________________________________________________________________
-
- NNAAMMEE
- Sync_Wait - wait on a monitor condition variable
-
- SSYYNNOOPPSSIISS
- ##iinncclluuddee <<ssyynncc..hh>>
- SSyynncc__WWaaiitt(_c_o_n_d_i_t_i_o_n_P_t_r, _w_a_k_e_I_f_S_i_g_n_a_l)
-
- AARRGGUUMMEENNTTSS
- Sync_Condition *_c_o_n_d_i_t_i_o_n_P_t_r (in) Address of a con-
- dition variable
- to distinguish
- waiting process
- for later notifi-
- cation.
-
- Boolean _w_a_k_e_I_f_S_i_g_n_a_l (in) This parameter is
- currently
- ignored.
-
- _________________________________________________________________
-
- DDEESSCCRRIIPPTTIIOONN
- SSyynncc__WWaaiitt allows a process using a monitor to wait for a
- particular condition. This routine can only be called while
- a monitor lock is aquired because it is only safe to check
- global state while in the monitor. This call releases the
- monitor lock and makes the process sleep on the condition.
- Other processes waiting on the monitor lock will become
- runnable. The process remains asleep until some other pro-
- cess invokes SSyynncc__BBrrooaaddccaasstt with the same condition vari-
- able.
-
- Because broadcast semantics are used, it is possible for
- spurious wakeups to occur if multiple processes are awaiting
- the same condition. Additionally, all processes waiting on
- *_c_o_n_d_i_t_i_o_n_P_t_r will be awakened simultaneously and may exe-
- cute in any order. For these reasons, when a process
- resumes execution it may find that the condition it was
- awaiting is no longer valid. In this case, it should call
- SSyynncc__WWaaiitt again.
-
- When the process awakens due to event notification through
- SSyynncc__BBrrooaaddccaasstt, SSUUCCCCEESSSS is returned.
-
- SSEEEE AALLSSOO
- Sync, Sync_Broadcast, Sig_Send
-
- KKEEYYWWOORRDDSS
- synchronization, wait, block, signal, process, event
-
-
-
-
-
-
- Sprite v.1.0 Printed: September 13, 1990 1
-
-
-
-